package com.albaba.designpattern.singleton;

import java.lang.reflect.Constructor;
import java.lang.reflect.InvocationTargetException;
import java.util.concurrent.LinkedBlockingQueue;
import java.util.concurrent.ThreadFactory;
import java.util.concurrent.ThreadPoolExecutor;
import java.util.concurrent.TimeUnit;

/**
 * @Description: TODO
 * @Author zx
 * @Date 2025/2/18 16:46
 * @Version 1.0
 */
public class Test_Singleton_004 {
    public static void main(String[] args) throws Exception {

        Class<Singleton_007> aClass = Singleton_007.class;

        Constructor<Singleton_007> constructor = aClass.getDeclaredConstructor();

        // 设置为ture后，就可以对类中的私有成员进行操作
        constructor.setAccessible(true);

        Singleton_007 singleton007 = constructor.newInstance();

        System.out.println(singleton007);
    }
}
